//
//  BaseModel.m
//  

#import "BaseModel.h"

@implementation BaseModel

MJExtensionLogAllProperties
MJExtensionCodingImplementation

-(id)init
{
    if(self=[super init])
    {
        [BaseModel mj_referenceReplacedKeyWhenCreatingKeyValues:YES];
    }
    return self;
}


- (id)mj_newValueFromOldValue:(id)oldValue property:(MJProperty *)property
{
    if (oldValue == nil &&property.type.typeClass == [NSString class]) return @"";
    else if (property.type.typeClass == [NSDate class]){
    
    }
    
    return oldValue;
}

- (id)valueForUndefinedKey:(NSString *)key {
    
    //for load more keyword
    if ([key isEqualToString:@"totalCount"]) {
        return @0;
    }
    
    return nil;
}



@end
